package com.newcapec.service.impl;

import com.newcapec.bean.UserEntity;
import com.newcapec.dao.SysUserDao;
import com.newcapec.dao.impl.SysUserDaoImpl;
import com.newcapec.service.SysUserService;

import java.util.List;

/**
 * @Description:业务层
 * @Author:yangshupeng
 * @Date: 2022/3/28 22:14
 * @Version:1.0
 */
public class SysUserServiceImpl implements SysUserService {
    SysUserDao sysUserDao = new SysUserDaoImpl();
    @Override
    public boolean addUser(UserEntity userEntity) {
        return sysUserDao.addUser(userEntity);
    }

    @Override
    public boolean deleteUser(String id) {
        return sysUserDao.deleteUser(id);
    }


    @Override
    public boolean updateUser(UserEntity userEntity) {
        return sysUserDao.updateUser(userEntity);
    }

    @Override
    public List<UserEntity> queryAll(int offset,int pageSize,UserEntity user) {
        return sysUserDao.queryAll(offset,pageSize,user);
    }

    @Override
    public UserEntity queryUserById(String id) {
        return sysUserDao.queryUserById(id);
    }

    @Override
    public UserEntity queryUserByAcct(String acct) {
        return sysUserDao.queryUserByAcct(acct);
    }

    @Override
    public int getAllCount(String name) {
        return sysUserDao.getAllCount(name);
    }



}
